<!--<ng-template #register let-c="close" let-d="dismiss">-->
<div class="modal-header">
  <h4 class="modal-title">登录</h4>
  <!--<button type="button" class="close" aria-label="Close" (click)="activeModal.dismiss('Cross click')">-->
  <!--<span aria-hidden="true">&times;</span>-->
  <!--</button>-->
</div>

<div class="modal-body">
  <form #registerForm="ngForm">
    <div class="formItem">
      <label>用户名：</label>
      <input type="text" required name="userName" [(ngModel)]="user.user_name" #username="ngModel">
      <span [hidden]="username.valid || username.pristine" class="prompt">请您输入用户名</span>
    </div>

    <div class="formItem" >
      <label>密码：</label>
      <input type="password" required name="userPsd" [(ngModel)]="user.user_pwd" #userpsd="ngModel">
      <span [hidden]="userpsd.valid || userpsd.pristine"  class="prompt">请您输入密码</span>
    </div>

    <div class="formItem" id="character">
      <input type="radio" required name="identity" value="teacher" [(ngModel)]="user.identity" #id="ngModel"> 教师
      <input type="radio" required name="identity" value="student" [(ngModel)]="user.identity" #id="ngModel"> 学生
    </div>
  </form>
</div>

<div class="modal-footer">
  <button type="button" class="btn btn-outline-dark" (click)="onSubmit()"
          [disabled]="(!username.valid) || (!userpsd.valid) || (!id.valid)">确认</button>
  <button type="button" class="btn btn-outline-dark" (click)="closeWindow()">取消</button>
</div>
<!--</ng-template>-->
